<{include file="admincp_header.htm"}>
<script language="javascript">
var i = 0;
function addvariable() {
	i ++;
	$("#addheader").after("<tr><td></td><td><input type='text' style='width:100px;' name='variable_" + i + "' value=''></td><td><input type='text' style='width:220px;' name='description_" + i + "' /></td><td><input type='text' style='width:220px;' name='standby_" + i + "' value='' /></td><td><select name='type_" + i + "'><{$typeoptions}></select></td><td></td><td></td>");
}
function deletevariable(variable) {
	if(confirm('<{$lan.suredelvariable}>')) {
		document.location='index.php?file=admincp&action=variables&job=delete&vc=<{$vc}>&variable=' + variable;
	}
}
function editvariable(variable) {
	document.location='index.php?file=admincp&action=variable&variable=' + variable;
}
</script>
<body>
<div class="block"></div>
<table cellspacing="1" cellpadding="4" class="commontable width100">
	<tr class="header">
		<td colspan="3"><div class="righttop"><a href="<{h name='custom-variables'}>" target="_blank"><{$lan.help}></a></div><{$lan.variable}></td>
	</tr>
	<tr>
		<td>
		<form enctype="multipart/form-data" action="index.php?file=admincp&action=variables&job=save" method="post">
		<table cellpadding="4" cellspacing="1" id="variables" class="commontable width100">
			<tr class="header">
				<td width="30">ID</td>
				<td width="60"><{$lan.variable}></td>
				<td width="158"><{$lan.description}></td>
				<td width="88"><{$lan.standby}></td>
				<td width="30"><{$lan.type}></td>
				<td><{$lan.data}></td>
				<td width="35"><{$lan.delete}></td>
			</tr>
			<{$variables}>
			<tr id="addheader" class="header"><td colspan="7"><a href='javascript:addvariable()'>+<{$lan.add}></a></td></tr>
		</table>
		<div class="block2"></div>
		<center><input type="submit" value="<{$lan.save}>" /></center>
		</form>
		</td>
	</tr>
</table>
</body>
</html>